package com.wdemo.config;

import com.wdemo.tools.OrderTools;
import com.wdemo.tools.ServeItemTool;
import org.springframework.ai.support.ToolCallbacks;
import org.springframework.ai.tool.ToolCallback;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.List;

/**
 * @ClassName McpConfig
 * @Description Mcp服务配置类
 * @Author WDEMO
 * @Date 2025/9/1 19:40
 */
@Configuration
public class McpConfig {



    /**
     * 申明对外提供服务的工具
     */
    @Bean
    public List<ToolCallback> serveItemTools(ServeItemTool serveItemTool,
                                             OrderTools orderTools) {
        return List.of(ToolCallbacks.from(serveItemTool,orderTools));
    }
}
